import { Injectable } from '@angular/core';
import {SimpleJsonFormatter} from '../../../ng-tools';

@Injectable({
  providedIn: 'root'
})
export class AllChannelFormatterService {
  name: SimpleJsonFormatter = {propName: 'name', displayName: '节目名称'};
  serviceProvider: SimpleJsonFormatter = {propName: 'provider_name', displayName: '服务提供商'};
  frequency: SimpleJsonFormatter = {propName: 'freq', displayName: '频率'};
  coderate: SimpleJsonFormatter = {propName: 'coderate', displayName: '码率'};
  modulatorModel: SimpleJsonFormatter = {propName: 'modulation', displayName: '调制器模式'};
  delivery_system: SimpleJsonFormatter = {propName: 'delivery_system', displayName: 'QAM类型'};
  srate: SimpleJsonFormatter = {propName: 'srate', displayName: '符号率'};
  sid: SimpleJsonFormatter = {propName: 'sid', displayName: 'SID'};
  pmt: SimpleJsonFormatter = {propName: 'pmt', displayName: 'PMT'};
  pcr: SimpleJsonFormatter = {propName: 'pcr', displayName: 'PCR'};
  video_id: SimpleJsonFormatter = {propName: 'video_id', displayName: '视频ID'};
  audio_id: SimpleJsonFormatter = {propName: 'audio_id', displayName: '音频ID'};
  subtitle: SimpleJsonFormatter = {propName: 'subtitle', displayName: '字幕'};
  caid: SimpleJsonFormatter = {propName: 'caid', displayName: 'CAID'};
  constructor() { }
  get formatter() {
    return [
      this.name,
      this.serviceProvider,
      this.coderate,
      this.frequency,
      this.modulatorModel,
      this.delivery_system,
      this.srate,
      this.sid,
      this.pmt,
      this.pcr,
      this.video_id,
      this.audio_id,
      this.subtitle,
      this.caid
    ];
  }
}
